/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.nms.entities;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import javax.xml.bind.annotation.XmlRootElement;

/**
 *
 * @author mohamedemara
 */
@Entity
@Table(name = "OFFERS")
@XmlRootElement
@NamedQueries({
    @NamedQuery(name = "Offers.findAll", query = "SELECT o FROM Offers o"),
    @NamedQuery(name = "Offers.findByOfferId", query = "SELECT o FROM Offers o WHERE o.offerId = :offerId"),
    @NamedQuery(name = "Offers.findByIspId", query = "SELECT o FROM Offers o WHERE o.ispId = :ispId"),
    @NamedQuery(name = "Offers.findByOfferName", query = "SELECT o FROM Offers o WHERE o.offerName = :offerName"),
    @NamedQuery(name = "Offers.findByOfferSpeed", query = "SELECT o FROM Offers o WHERE o.offerSpeed = :offerSpeed"),
    @NamedQuery(name = "Offers.findByOfferType", query = "SELECT o FROM Offers o WHERE o.offerType = :offerType"),
    @NamedQuery(name = "Offers.findByOfferDownloadToUpload", query = "SELECT o FROM Offers o WHERE o.offerDownloadToUpload = :offerDownloadToUpload"),
    @NamedQuery(name = "Offers.findByOfferSubscriptionprice", query = "SELECT o FROM Offers o WHERE o.offerSubscriptionprice = :offerSubscriptionprice"),
    @NamedQuery(name = "Offers.findByOfferMontlyprice", query = "SELECT o FROM Offers o WHERE o.offerMontlyprice = :offerMontlyprice"),
    @NamedQuery(name = "Offers.findByOfferAces", query = "SELECT o FROM Offers o WHERE o.offerAces = :offerAces")})
public class Offers implements Serializable {
    private static final long serialVersionUID = 1L;
    @Id
    @Basic(optional = false)
    @NotNull
    @Size(min = 1, max = 10)
    @Column(name = "offer_id")
    private String offerId;
    @Basic(optional = false)
    @NotNull
    @Size(min = 1, max = 10)
    @Column(name = "isp_id")
    private String ispId;
    @Basic(optional = false)
    @NotNull
    @Size(min = 1, max = 15)
    @Column(name = "offer_name")
    private String offerName;
    @Basic(optional = false)
    @NotNull
    @Size(min = 1, max = 5)
    @Column(name = "offer_speed")
    private String offerSpeed;
    @Basic(optional = false)
    @NotNull
    @Size(min = 1, max = 10)
    @Column(name = "offer_type")
    private String offerType;
    @Size(max = 5)
    @Column(name = "offer_download_to_upload")
    private String offerDownloadToUpload;
    @Basic(optional = false)
    @NotNull
    @Column(name = "offer_subscriptionprice")
    private int offerSubscriptionprice;
    @Basic(optional = false)
    @NotNull
    @Column(name = "offer_montlyprice")
    private int offerMontlyprice;
    @Size(max = 150)
    @Column(name = "offer_Aces")
    private String offerAces;

    public Offers() {
    }

    public Offers(String offerId) {
        this.offerId = offerId;
    }

    public Offers(String offerId, String ispId, String offerName, String offerSpeed, String offerType, int offerSubscriptionprice, int offerMontlyprice) {
        this.offerId = offerId;
        this.ispId = ispId;
        this.offerName = offerName;
        this.offerSpeed = offerSpeed;
        this.offerType = offerType;
        this.offerSubscriptionprice = offerSubscriptionprice;
        this.offerMontlyprice = offerMontlyprice;
    }

    public String getOfferId() {
        return offerId;
    }

    public void setOfferId(String offerId) {
        this.offerId = offerId;
    }

    public String getIspId() {
        return ispId;
    }

    public void setIspId(String ispId) {
        this.ispId = ispId;
    }

    public String getOfferName() {
        return offerName;
    }

    public void setOfferName(String offerName) {
        this.offerName = offerName;
    }

    public String getOfferSpeed() {
        return offerSpeed;
    }

    public void setOfferSpeed(String offerSpeed) {
        this.offerSpeed = offerSpeed;
    }

    public String getOfferType() {
        return offerType;
    }

    public void setOfferType(String offerType) {
        this.offerType = offerType;
    }

    public String getOfferDownloadToUpload() {
        return offerDownloadToUpload;
    }

    public void setOfferDownloadToUpload(String offerDownloadToUpload) {
        this.offerDownloadToUpload = offerDownloadToUpload;
    }

    public int getOfferSubscriptionprice() {
        return offerSubscriptionprice;
    }

    public void setOfferSubscriptionprice(int offerSubscriptionprice) {
        this.offerSubscriptionprice = offerSubscriptionprice;
    }

    public int getOfferMontlyprice() {
        return offerMontlyprice;
    }

    public void setOfferMontlyprice(int offerMontlyprice) {
        this.offerMontlyprice = offerMontlyprice;
    }

    public String getOfferAces() {
        return offerAces;
    }

    public void setOfferAces(String offerAces) {
        this.offerAces = offerAces;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (offerId != null ? offerId.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof Offers)) {
            return false;
        }
        Offers other = (Offers) object;
        if ((this.offerId == null && other.offerId != null) || (this.offerId != null && !this.offerId.equals(other.offerId))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "com.nms.entities.Offers[ offerId=" + offerId + " ]";
    }
    
}
